﻿using System;
using Autodesk.Revit.Attributes;
using Autodesk.Revit.DB;
using Autodesk.Revit.UI;

namespace QuickModel.Demo
{
	[Transaction(TransactionMode.Manual)]
	public class DemoCmdLoop : IExternalCommand
	{
		public Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements)
		{
			UseRequestMaker useRequestMaker = new UseRequestMaker(commandData.Application.ActiveUIDocument);
			QuickModelFrameWork quickModelFrameWork = new QuickModelFrameWork(useRequestMaker, new UseRespondHanlder());
			quickModelFrameWork.ExcuteWithWhile(commandData);
			return Autodesk.Revit.UI.Result.Succeeded;
		}
	}
}
